from django.db import models

# Create your models here.
class User(models.Model):
    username = models.CharField(max_length=20)
    user_level = models.IntegerField()

    class Meta:
        db_table = 'user'

    def __str__(self):
        return self.username

class Goods(models.Model):
    title = models.CharField(max_length=20)
    price = models.DecimalField(max_digits=5,decimal_places=1)

    class Meta:
        db_table = 'goods'

    def __str__(self):
        return self.title

class Page(models.Model):
    price = models.IntegerField()

    class Meta:
        db_table = 'page'

    def __str__(self):
        return self.price

